package com.jt.config;

import com.jt.vo.SysResult;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

/**
 * @version 创建时间：2021/8/11 23:51
 * @author： Colin
 */
@RestControllerAdvice
public class MyExceptionAdvice {
    @ExceptionHandler(RuntimeException.class)
    public Object exception(Exception e){
        e.printStackTrace();
        return SysResult.fail();

    }
}
